{# One series, live: where it was read from, then a tab each for its run over time (a headline, then a card per part that has points: settled, shifted, still open, the mood, each point folding open to its lines) and what it keeps coming back to (_threads.html), each line opening its meeting; and the series written again. While it is being written it re-reads itself every few seconds. #} {% from "components/macros/layout.html" import card, facts, tab_panel, tabbed %} {% from "components/macros/form.html" import action %} {% from "pages/overseer/meetings/_threads.html" import quote_lines, thread_sections %} {% set marks = {"settled": "✓", "shifted": "↗", "still_open": "•"} %} {% set series = record.series %}
{{ facts([ ("Owner", series.owner_user_id), ("Link", series.link), ("Read from", series.meetings ~ (" meeting" if series.meetings == 1 else " meetings")), ("Written by", series.model_name), ("Written", written), ]) }} {% if series.error %}{% endif %} {% if record.writing %}

Writing the series…

{% endif %} {% set open = "summary" %} {% call tabbed("series", [("summary", "Over time"), ("themes", "Keeps coming up")], open) %} {% call tab_panel("summary", open) %} {% call card(None, id="series-summary", hover=False) %}

{{ series.summary or "Nothing yet." }}

{% endcall %}
{% for part in record.over_time %} {% call card(part.title, id="series-" ~ part.key, hover=False) %} {% endcall %} {% endfor %}
{% endcall %} {% call tab_panel("themes", open) %}{{ thread_sections(record.sections, said) }}{% endcall %} {% endcall %} {% if record.can_write %}
{{ action("Write it again", 'data-write-series data-write hx-post="' ~ base ~ '/write" hx-target="#series-body" hx-swap="outerHTML"') }}
{% endif %}